package com.validator.exception;

/**
 * 应用程序异常
 *
 * @author Amadeus
 * @date 2022/07/07
 */
public class AppException extends RuntimeException {
	private static final long serialVersionUID = 1L;

	private  int code= 500;
	private String msg;

	public AppException(String message){
		super(message);
		this.msg = message;
	}

	public AppException(int code, String message){
		super(message);
		this.code=code;
		this.msg = message;
	}

	public AppException(Throwable cause)
	{
		super(cause);
	}
	
	public AppException(String message, Throwable cause)
	{
		super(message,cause);
	}


	public int getCode() {
		return code;
	}

	public void setCode(int code) {
		this.code = code;
	}

	public String getMsg() {
		return msg;
	}

	public void setMsg(String msg) {
		this.msg = msg;
	}
}
